package com.hehao.kurunner.ui.mine;

import android.view.View;
import android.widget.Toast;

import com.hehao.kurunner.R;
import com.hehao.kurunner.common.BaseActivity;

/**
 * 个人中心设置activity
 *
 * @author Jack
 * @time 2015/11/18 14:15
 * @email bnbzhb@qq.com
 */
public class SettingActivity extends BaseActivity {
    @Override
    protected void initData() {
    }

    @Override
    protected void initView() {
//        setContentView(R.layout.activity_setting);
        setLayoutWithCommonHeader(R.layout.activity_setting);
        setHeadLeft(R.drawable.ico_back);
        setHeadTitle(R.string.setting_setting);
        getViewWithClick(R.id.rl_settest1);
        getViewWithClick(R.id.rl_settest2);
        getViewWithClick(R.id.rl_settest3);
        getViewWithClick(R.id.tv_changeacc);
    }

    @Override
    protected void onViewClick(View v) {
        if (v.getId() == R.id.rl_settest1) {
            Toast.makeText(context, "No.1", Toast.LENGTH_SHORT).show();
        } else if (v.getId() == R.id.rl_settest2) {
            Toast.makeText(context, "No.2", Toast.LENGTH_SHORT).show();
        } else if (v.getId() == R.id.rl_settest3) {
            Toast.makeText(context, "No.3", Toast.LENGTH_SHORT).show();
        } else if (v.getId() == R.id.tv_changeacc) {
            Toast.makeText(context, "Change account", Toast.LENGTH_SHORT).show();
        } else {
            Toast.makeText(context, "test click", Toast.LENGTH_SHORT).show();
        }
    }


    /**
     * 点击标题左侧按键返回个人中心
     */
    @Override
    protected void onLeftClick() {
        finish();
    }
}
